package com.sf.service.impl;

import com.sf.domain.Employee;
import com.sf.mapper.EmployeeMapper;
import com.sf.service.IEmployeeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
@Service
public class EmployeeServiceImpl implements IEmployeeService {
    @Autowired
    private EmployeeMapper employeeMapper;
    @Override



    public List<Employee> list() {
        return employeeMapper.list();
    }

    @Override
    public void insert(Employee employee) {
       employeeMapper.insert(employee);
    }

    @Override
    public void update(Employee employee, Long id) {
        employeeMapper.update(employee, id);
    }

    @Override
    public void delete(Long id) {
        employeeMapper.delete(id);
    }

    @Override
    public Employee get(Long id) {
        employeeMapper.get(id);
    }
}
